CLS SCREEN 2,640,200,4,2 WINDOW 2,,,0,2 WINDOW OUTPUT 2 CLEAR RANDOMIZE TIMER PALETTE 0,0,0,0.5 PALETTE 1,1,1,1 PALETTE 2,0,0,0 PALETTE 3,0.6,0.6,0.6 PALETTE 5,0.8,0,0 PALETTE 6,0,0.6,0 PALETTE 7,0.8,0,0.8 PALETTE 8,1,0.8,0 PALETTE 9,1,0.6,0.1 PALETTE 10,1,0.5,0 PALETTE 11,0.3,0.3,0.3 PALETTE 12,0.3,0,0 GOSUB title CLS x=20:y=10:p=5 GOSUB vstitle handle: LINE (550,140)-(600,190),1,b PAINT STEP (5,5),6,1 LINE (575,140)-(600,45),1,b PAINT STEP(5,5),6,1 LINE (576,140)-(599,140),6 CIRCLE (587,30),35,1,,,0.44 PAINT STEP (0,0),2,1 LINE (580,32)-(595,39),5,bf LINE (586,35)-(589,36),2,bf LOCATE 4,72:COLOR 1,2 PRINT "pull":COLOR 1,0 GOSUB drawboxes coinslot: CIRCLE (400,30),50,1,,,0.44 CIRCLE (400,0),70,1,4.71-0.7,4.71+0.7,0.44 CIRCLE (400,0),60,1,4.71-0.8,4.71+0.8,0.44 PAINT STEP (0,20),12,1 PAINT STEP (0,10),2,1 PAINT STEP (0,20),11,1 LOCATE 3,50:COLOR 1,12 PRINT "$1":COLOR 1,0 quitspot: LINE (5,185)-(20,192),1,b LINE (11,188)-(14,189),1,bf PAINT STEP(-2,-2),2,1 LOCATE 24,4 PRINT "quit"; GOSUB winbox mousecheck: IF MOUSE(0)<>0 AND MOUSE(5)>5 AND MOUSE(5)<20 AND MOUSE(6)>185 AND MOUSE(6)<192 THEN GOTO fin IF MOUSE(0)<>0 AND MOUSE(5)>580 AND MOUSE(5)<595 AND MOUSE(6)>32 AND MOUSE(6)<39 THEN GOTO play IF MOUSE(0)<>0 AND MOUSE(5)>550 AND MOUSE(5)<552 AND MOUSE(6)>140 AND MOUSE(6)<142 THEN GOSUB fakejack GOTO mousecheck fakejack: turns=turns+1 GOSUB drawboxes GOSUB winbox x=80:GOSUB bar x=260:GOSUB bar x=440:GOSUB bar a=6:b=6:c=6 GOSUB pay GOSUB printpay RETURN play: turns=turns+1 GOSUB drawboxes GOSUB winbox x=80 GOSUB roll a=n x=260 GOSUB roll b=n x=440 GOSUB roll c=n GOSUB pay GOSUB printpay GOTO mousecheck winbox: LINE (175,140)-(425,170),1,b LINE (176,141)-(424,169),11,bf RETURN pay: IF a=6 AND b=6 AND c=6 THEN p$="THE JACKPOT - $1,000":money=money+1000:RETURN IF a=5 AND b=5 AND c=5 THEN p$="$18":money=money+18:RETURN IF a=5 AND b=5 AND c=6 THEN p$="$18":money=money+18:RETURN IF a=4 AND b=4 AND c=4 THEN p$="$14":money=money+14:RETURN IF a=4 AND b=4 AND c=6 THEN p$="$14":money=money+14:RETURN IF a=3 AND b=3 AND c=3 THEN p$="$10":money=money+10:RETURN IF a=3 AND b=3 AND c=6 THEN p$="$10":money=money+10:RETURN IF a=2 AND b=2 AND c=2 THEN p$="$6":money=money+6:RETURN IF a=2 AND b=2 AND c=6 THEN p$="$6":money=money+6:RETURN IF a=2 AND b=2 THEN p$="$4":money=money+4:RETURN IF a=2 THEN p$="$2":money=money+2:RETURN p$="":RETURN printpay: LOCATE 20,33 IF p$="" THEN RETURN IF p$="THE JACKPOT - $1,000" THEN LOCATE 20,25 PRINT "You win ";p$ IF p$="THE JACKPOT - $1,000" THEN GOSUB jack RETURN jack: FOR y=0 TO 50 FOR x=1000 TO 100 STEP -200 SOUND x,1,255,INT(RND*3+1) PALETTE 0,RND,RND,RND NEXT x NEXT y PALETTE 0,0,0,0.5 RETURN fin: CLS LOCATE 5,25 PRINT "Thank You for playing SLOTMACHINE" LOCATE 10,28 PRINT "You spent $";turns LOCATE 12,28 PRINT "and your winnings were $";money;"." LOCATE 20,25 PRINT "Press any key to end." checkend: zzz$=INKEY$:IF zzz$="" THEN GOTO checkend WINDOW CLOSE 2:SCREEN CLOSE 2 END orange: CIRCLE (x+50,107),25,2,,,0.44 PAINT STEP (0,0),10,2 CIRCLE STEP (5,-6),4,2,,,0.22 RETURN cherry: CIRCLE (x+35,108),20,2,,,0.44 PAINT STEP (0,0),5,2 CIRCLE STEP (30,10),40,6,1,2.1,0.44 CIRCLE STEP (0,0),39,6,1,2.1,0.44 RETURN plum: CIRCLE (x+35,108),30,2,,,0.3 PAINT STEP (0,0),7,2 CIRCLE STEP (33,15),40,2,0.8,1.7,0.44 CIRCLE STEP (0,0),39,2,0.8,1.7,0.44 RETURN bar: IF x=80 THEN c=15 IF x=260 THEN c=37 IF x=440 THEN c=60 LINE (x,98)-(x+100,98),2 LINE (x,100)-(x+100,114),2,bf LINE (x,116)-(x+100,116),2 COLOR 1,2 LOCATE 14,c:PRINT "B A R" COLOR 1,0 RETURN bell: CIRCLE (x+50,101),20,2,0,3.14,0.44 LINE STEP (-20,0)-STEP(0,4),2 LINE STEP (40,-4)-STEP(0,4),2 CIRCLE STEP (20,0),20,2,3.14,4.71,0.44 CIRCLE STEP (-80,0),20,2,4.71,6.28,0.44 CIRCLE STEP (40,-40),120,2,4.71-0.35,4.71+0.35,0.44 PAINT STEP(0,40),9,2 CIRCLE STEP (0,15),5,2,,,0.44 PAINT STEP (0,0),9,2 RETURN lemon: CIRCLE (x+50,107),30,2,,,0.3 PAINT STEP (0,0),8,2 CIRCLE STEP(25,0),2,2,,,0.66 RETURN roll: r=INT(RND*100)+1 IF r>89 THEN n=6:GOSUB bar:RETURN IF r<90 AND r>72 THEN n=5:GOSUB bell:RETURN IF r<73 AND r>54 THEN n=4:GOSUB plum:RETURN IF r<55 AND r>36 THEN n=3:GOSUB orange:RETURN IF r<37 AND r>18 THEN n=2:GOSUB cherry:RETURN IF r<19 THEN n=1:GOSUB lemon:RETURN drawboxes: FOR x=80 TO 440 STEP 180 LINE (x-20,90)-(x+120,125),3,bf LINE (x-20,90)-(x+120,125),1,b NEXT x RETURN vstitle: LINE (x,y)-STEP(10,0) LINE STEP(0,0)-STEP(10,10) LINE STEP(0,0)-STEP(10,-10) LINE STEP(0,0)-STEP(10,0) LINE STEP(0,0)-STEP(-20,20) LINE STEP(0,0)-STEP(-20,-20) PAINT STEP(5,2),p,1 LINE (x+50,y)-STEP(30,0) LINE STEP(0,0)-STEP(0,5) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,3) LINE STEP(0,0)-STEP(10,0) LINE STEP(0,0)-STEP(0,4) LINE STEP(0,0)-STEP(-10,0) LINE STEP(0,0)-STEP(0,3) LINE STEP(0,0)-STEP(20,0) LINE STEP(0,0)-STEP(0,5) LINE STEP(0,0)-STEP(-30,0) LINE STEP(0,0)-STEP(0,-20) PAINT STEP(2,2),p,1 LINE (x+90,y)-STEP(30,0) LINE STEP(0,0)-STEP(0,5) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,10) LINE STEP(0,0)-STEP(10,0) LINE STEP(0,0)-STEP(0,-3) LINE STEP(0,0)-STEP(-4,0) LINE STEP(0,0)-STEP(0,-4) LINE STEP(0,0)-STEP(14,0) LINE STEP(0,0)-STEP(0,12) LINE STEP(0,0)-STEP(-30,0) LINE STEP(0,0)-STEP(0,-20) PAINT STEP (2,2),p,1 LINE (x+140,y)-STEP(20,0) LINE STEP(0,0)-STEP(10,20) LINE STEP(0,0)-STEP(-10,0) LINE STEP(0,0)-STEP(-4,-7) LINE STEP(0,0)-STEP(-12,0) LINE STEP(0,0)-STEP(-4,7) LINE STEP(0,0)-STEP(-10,0) LINE STEP(0,0)-STEP(10,-20) LINE STEP(5,9)-STEP(2,-3) LINE STEP(0,0)-STEP(4,0) LINE STEP(0,0)-STEP(3,4) LINE STEP(0,0)-STEP(-8,0) PAINT STEP(0,2),p,1 LINE (x+180,y)-STEP(30,0) LINE STEP(0,0)-STEP(0,5) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,3) LINE STEP(0,0)-STEP(20,0) LINE STEP(0,0)-STEP(0,12) LINE STEP(0,0)-STEP(-30,0) LINE STEP(0,0)-STEP(0,-5) LINE STEP(0,0)-STEP(20,0) LINE STEP(0,0)-STEP(0,-3) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,-12) PAINT STEP(2,2),p,1 LINE (x+20,y+30)-STEP(40,0) LINE STEP(0,0)-STEP(0,10) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,5) LINE STEP(0,0)-STEP(20,0) LINE STEP(0,0)-STEP(0,20) LINE STEP(0,0)-STEP(-40,0) LINE STEP(0,0)-STEP(0,-10) LINE STEP(0,0)-STEP(20,0) LINE STEP(0,0)-STEP(0,-5) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,-20) PAINT STEP(2,2),p,1 LINE (x+70,y+30)-STEP(20,0) LINE STEP(0,0)-STEP(0,25) LINE STEP(0,0)-STEP(20,0) LINE STEP(0,0)-STEP(0,10) LINE STEP(0,0)-STEP(-40,0) LINE STEP(0,0)-STEP(0,-35) PAINT STEP(2,2),p,1 LINE(x+120,y+30)-STEP(40,0) LINE STEP(0,0)-STEP(0,35) LINE STEP(0,0)-STEP(-40,0) LINE STEP(0,0)-STEP(0,-35) LINE STEP(10,10)-STEP(20,0) LINE STEP(0,0)-STEP(0,15) LINE STEP(0,0)-STEP(-20,0) LINE STEP(0,0)-STEP(0,-15) PAINT STEP(-2,-2),p,1 LINE (x+170,y+30)-STEP(40,0) LINE STEP(0,0)-STEP(0,10) LINE STEP(0,0)-STEP(-14,0) LINE STEP(0,0)-STEP(0,25) LINE STEP(0,0)-STEP(-12,0) LINE STEP(0,0)-STEP(0,-25) LINE STEP(0,0)-STEP(-14,0) LINE STEP(0,0)-STEP(0,-10) PAINT STEP(2,2),p,1 RETURN title: x=195:y=15:p=5 GOSUB vstitle GOSUB drawboxes FOR x=80 TO 440 STEP 180 GOSUB bar NEXT x LOCATE 18,39:PRINT "by" LOCATE 20,33:PRINT "KIP H. HAMMOND" LOCATE 23,20 PRINT "Press 'I' for Instructions, or 'P' to Play."; checkkey: zz$=UCASE$(INKEY$) IF zz$="P" THEN RETURN IF zz$="I" THEN GOTO instructions IF zz$="Q" THEN WINDOW CLOSE 2:END GOTO checkkey instructions: CLS LOCATE 3,27:PRINT "* * * * SLOTMACHINE * * * *" LOCATE 5,39:PRINT "by" LOCATE 7,33:PRINT "Kip H. Hammond" LOCATE 10,5 PRINT "To pull the Slotmachine's handle, just click the left mouse button on the" PRINT "'PULL' gadget on top of the handle. To QUIT, just click the 'QUIT' gadget" PRINT "and you will get a summary of your winnings (or losings!)." PRINT :PRINT PRINT " Payoffs are similar to Las Vegas slotmachine payoffs for the same rolls." PRINT "The odds of hitting a BAR in any window are 10 to 1, which makes the odds" PRINT "of hitting a Jackpot, three BARS, 1000 to 1." LOCATE 19,23:PRINT "* * * * GOOD LUCK !! * * * *" LOCATE 22,25:PRINT "Press any key to continue."; checkkey2: zz$="" zz$=UCASE$(INKEY$) IF zz$="" THEN GOTO checkkey2 :ELSE RETURN RETURN